Title Banner

Previous Book Contents Book Index Next

Inside Macintosh: QuickTime Components /
Chapter 8 - Video Digitizer Components / Video Digitizer Components Reference
Video Digitizer Component Functions / Selectively Displaying Video


VDGetMaskandValue

The VDGetMaskandValue function allows your application to obtain the appropriate alpha channel or blend mask value for a desired level of video blending. Your application specifies a desired level of video blend.

pascal VideoDigitizerError VDGetMaskandValue
                                  (VideoDigitizerComponent ci,
                                     unsigned short blendLevel,
                                     long *mask, long *value);
ci
Specifies the video digitizer component for the request. Applications obtain this reference from the Component Manager's OpenComponent function.
blendLevel
Specifies the desired blend level. Valid values range from 0 to 65,535, where 0 corresponds to no video and 65,535 corresponds to all video.
mask
Contains a pointer to a field that is to receive a value indicating which bits are meaningful in the data returned for the value parameter. The video digitizer component sets to 1 the bits that correspond to meaningful bits in the data returned for the value parameter.
value
Contains a pointer to a field that is to receive data that can be used to obtain the desired blend level. The data returned for the mask parameter indicates which bits are valid in the data returned for this parameter.
DESCRIPTION
The video digitizer returns the corresponding mask value. The application can then use this value to set the alpha channel or blend mask.

The information returned by the digitizer component differs based on the type of blending supported by the component. In all cases, however, the returned value of the value parameter contains the value for the desired blend level, and the returned value of the mask parameter indicates which bits in the value parameter are meaningful. Bits in the returned mask parameter value that are set to 1 correspond to meaningful bits in the returned value parameter value.

For example, if an application requests a 50 percent video blend level from a digitizer that supports 8-bit alpha channels, the digitizer component might return the following values:
mask0xFF000000Identifies full upper byte as the alpha channel
value0x80000000Value for 50 percent blend level

RESULT CODES
noErr0No error
digiUnimpErr-2201Function not supported

Previous Book Contents Book Index Next

© Apple Computer, Inc.
7 JUL 1996




Navigation graphic, see text links

Main | Top of Section | What's New | Apple Computer, Inc. | Find It | Feedback | Help